<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Movie</title>
</head>
<style>
    td{
        width: 300px;
    }
</style>
<body>
    <div class="list" style="width: 1200px;margin: 0 auto;">
        <div style="display:flex;align-items: center;justify-content: space-between;">
            <div>电影id</div>
            <div>电影名称</div>
            <div>电影评分</div>
        </div>
    </div>
    
</body>
<script src="https://code.jquery.com/jquery-3.1.1.min.js"></script>
<script>
    $.get("http://localhost:8081/getlist",function(data){
        var movieList = JSON.stringify(data);
        console.log(movieList);
        for(var i=0; i<movieList.length; i++){
            var htmlStr = "<tr><td>"+movieList[i]["movieId"]+"</td>"+"<td>"+movieList[i]["movieName"]+"</td>"+"<td>"+movieList[i]["movieRate"]+"</td></tr>"
            $(".list").append(htmlStr); 
        }
    })
</script>
</html>